Polyvariant Flow Analysis with Constrained Types

نویسندگان

  • Scott F. Smith
  • Tiejun Wang
چکیده

The basic idea behind improving the quality of a monovariant control flow analysis such as 0CFA is the concept of polyvariant analyses such as Agesen’s Cartesian Product Algorithm (CPA) and Shivers’ nCFA. In this paper we develop a novel framework for polyvariant flow analysis based on AikenWimmers constrained type theory. We develop instantiations of our framework to formalize various polyvariant algorithms, including nCFA and CPA. With our CPA formalization, we show the call-graph based termination condition for CPA will not always guarantee termination. We then develop a novel termination condition and prove it indeed leads to a terminating algorithm. Additionally, we show how data polymorphism can be modeled in the framework, by defining a simple extension to CPA that incorporates data polymorphism.

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

A polyvariant type analysis for Erlang

This paper presents a type analysis for the programming language Erlang. The analysis computes interprocedural control-flow and data-flow information, and should be applicable to any higher-order functional programming language with call-by-value semantics. The analysis uses a novel method for polyvariance, static limiting, where an approximation of the call graph is analyzed to determine wheth...

متن کامل

A calculus with polymorphic and polyvariant flow types

We present λ, a typed λ-calculus which serves as the foundation for a typed intermediate language for optimizing compilers for higher-order polymorphic programming languages. The key innovation of λ is a novel formulation of intersection and union types and flow labels on both terms and types. These flow types can encode polyvariant control and data flow information within a polymorphically typ...

متن کامل

Compiling with Polymorphic and Polyvariant Flow Types

Optimizing compilers for function-oriented and object-oriented languages exploit type and flow information for efficient implementation. Although type and flow information (both control and data flow) are inseparably intertwined, compilers usually compute and represent them separately. Partially, this has been a result of the usual polymorphic type systems using ∀ and ∃ quantifiers, which are d...

متن کامل

An Approach to Polyvariant Binding Time Analysis for a Stack-Based Language

Binding time analysis (BTA) is used in specialization by means of partial evaluation method. Usual BTA only annotates a source program. Polyvariant BTA transforms a source program to an annotated one. Polyvariant BTA is known technique for functional languages. In this paper polyvariant BTA for a model imperative stack-based language is presented. It is described by means of building annotated ...

متن کامل

Faithful Translations between Polyvariant Flows and Polymorphic Types

Recent work has shown equivalences between various type systems and flow logics. Ideally, the translations upon which such equivalences are based should be faithful in the sense that information is not lost in round-trip translations from flows to types and back or from types to flows and back. Building on the work of Nielson & Nielson and of Palsberg & Pavlopoulou, we present the first faithfu...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2000